﻿(function(exports){
	$(document).ready(function() {

		/*
		 * Define constructor and prototype for Bird
		 */
		function Bird(data) {
			this.data = data;
			this.id = data.id;
		};
		
		Bird.prototype.getImagePath = function() {
			return "data/images/" + this.data.id + "." + this.data.imageExtension;
		};
		
		Bird.prototype.getSoundPath = function() {
			return "data/sounds/" + this.data.id + "." + this.data.soundExtension;
		};
		
		Bird.prototype.getLocalizedName = function(locale) {
			return this.data["name_"+locale];
		};
		
		Bird.prototype.getLatinName = function(locale) {
			return this.data["name_la"];
		};
		
		Bird.prototype.getLocalizedDescription = function(locale) {
			return this.data["description_"+locale];
		}
		
		Bird.prototype.getLocalizedDescritpionAuthor = function(locale) {
			return this.data["descriptionAuthor_"+locale];
		}
		
		Bird.prototype.getLocalizedDescritpionLicense = function(locale) {
			return this.data["descriptionLicense_"+locale];
		}
		
		exports.Bird = Bird;
		
	});
})(window);